package net.siren93.smh.dao;

import java.io.Serializable;
import java.util.List;

/**
 * Created by siren93 on 15/9/25.
 */
public interface GenericDao<T, K extends Serializable> {

    T load(K id);
    T get(K id);
    List<T> findAll();
    void persist(T entity);
    K save(T entity);
    void saveOrUpdate(T entity);
    void delete(K id);
    void flush();

}
